The key motivation to evaluate a surrogate endpoint is to be able to predict the treatment effect on the true endpoint Pred.TrialT.ContCont
allows for making such predictions. The present plot function shows the results graphically.
# S3 method for PredTrialTContCont
plot(x, Size.New.Trial=5, CI.Segment=1, ...)
A fitted object of class Pred.TrialT.ContCont
, for details see Pred.TrialT.ContCont
.
The expected treatment effect on Size.New.Trial
. Default Size.New.Trial=5
.
The confidence interval around the expected treatment effect on CI.Segment
. Default
Extra graphical parameters to be passed to plot()
.
# NOT RUN {
# time consuming code part
# Generate dataset
Sim.Data.MTS(N.Total=2000, N.Trial=15, R.Trial.Target=.95,
R.Indiv.Target=.8, D.aa=10, D.bb=50,
Fixed.Effects=c(1, 2, 30, 90), Seed=1)
# Evaluate surrogacy using a reduced bivariate mixed-effects model
BimixedFit <- BimixedContCont(Dataset = Data.Observed.MTS,
Surr = Surr, True = True, Treat = Treat, Trial.ID = Trial.ID,
Pat.ID = Pat.ID, Model="Reduced")
# Suppose that in a new trial, it was estimated alpha_0 = 30
# predict beta_0 in this trial
Pred_Beta <- Pred.TrialT.ContCont(Object = BimixedFit,
alpha_0 = 30)
# Examine the results
summary(Pred_Beta)
# Plot the results
plot(Pred_Beta)
# }
Run the code above in your browser using DataLab